﻿<%@ Page Title="" Language="C#" MasterPageFile="~/ANMCMaster.Master" AutoEventWireup="true" CodeBehind="ShoutOut.aspx.cs" Inherits="AllNations.UI.ShoutOut" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ANHeaderContent" runat="server">
    <script type="text/javascript">
        function changeToFormView() {
            var multiPage = $find("<%= NewShoutoutViews.ClientID %>");
            multiPage.set_selectedIndex(1);
            var selView = multiPage.get_selectedPageView();
            if (selView.get_element().hasChildNodes()) {
                var txtBoxes = selView.get_element().getElementsByTagName("TEXTAREA");
                if (txtBoxes.length > 0) {
                    txtBoxes[0].focus();
                }
            }
        }
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ANPageHeader" runat="server">
    <telerik:RadMultiPage ID="CustomStyles" runat="server" RenderSelectedPageOnly="true">
        <telerik:RadPageView ID="viewEnglish" runat="server">
            <style type=""text/css"">
                Table.Shoutout span.username, Table.Shoutout span.content, Table.Shoutout span.date {
                    font-family: Arial, Helvetica, sans-serif !important;
                }
                Table.Shoutout span.username, Table.Shoutout span.content {
                    font-size: 9pt !important;
                }
                Table.Shoutout span.username {
                    color: #0099ff;
                }
                Table.Shoutout span.date {
                    font-size: 8pt !important;
                }
            </style>
        </telerik:RadPageView>
        <telerik:RadPageView ID="viewKorean" runat="server">
        </telerik:RadPageView>
    </telerik:RadMultiPage>
    <asp:Image ID="Image1" runat="server" ImageUrl="~/Images/YouthGroup.jpg" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ANBodyContent" runat="server">
    <div class="leftnav">
        <telerik:RadMultiPage ID="LeftNavigationViews" runat="server" RenderSelectedPageOnly="true" SelectedIndex="0">
            <telerik:RadPageView ID="viewYouthGroup" runat="server">
                <div style="margin: 11px 0px 25px 0px;"><asp:Image ID="Image2" runat="server" ImageUrl="~/Images/sectionTitleYouthGroupHome.png" /></div>
                <telerik:RadMenu ID="radMenuLeftNavYouthGroup" runat="server" EnableEmbeddedSkins="false" Skin="ANMCLeftNav">
                    <Items>
                        <telerik:RadMenuItem Text="Home" Value="Home" NavigateUrl="~/YouthGroup"></telerik:RadMenuItem>
                        <telerik:RadMenuItem Text="Announcements" Value="Announcements" NavigateUrl="~/Announcements/YouthGroup"></telerik:RadMenuItem>
                        <telerik:RadMenuItem Text="Messageboard" Value="Messageboard" NavigateUrl="~/Shoutout/YouthGroup" Selected="true"></telerik:RadMenuItem>
                    </Items>
                </telerik:RadMenu>
            </telerik:RadPageView>
        </telerik:RadMultiPage>
    </div>
    <div class="rightcontentarea">
        <div id="contentBoxHolder">
            <div class="ContentTitleBar">
                <asp:Image ID="Image6" runat="server" ImageUrl="~/Images/titleYouthGroupHome.png" />
            </div>
            <article class="node static-page content">
                <asp:HiddenField ID="hidNewShoutoutId" runat="server" />
                <telerik:RadMultiPage ID="NewShoutoutViews" runat="server" RenderSelectedPageOnly="false" SelectedIndex="0">
                    <telerik:RadPageView ID="initialView" runat="server">
                        <div style="padding: 15px;"><asp:TextBox ID="txtFakeTextbox" runat="server" Width="95%" style="font-family: Arial, Verdana, Helvetica; color: #999; border: 1px solid #ccc; height: 30px; padding-left: 10px; background-color: White;" onclick="changeToFormView();">Enter your message.</asp:TextBox></div>
                    </telerik:RadPageView>
                    <telerik:RadPageView ID="formView" runat="server">
                        <table cellpadding="5" cellspacing="0" border="0" style="width: 100%">
                            <tr style="vertical-align: top">
                                <td style="width: 75px; border-bottom: 1px solid #ccc"><asp:Image runat="server" ID="imgMemberIcon" Width="75" ImageAlign="AbsMiddle" OnPreRender="imgMemberIcon_PreRender" /></td>
                                <td style="width: 100%; border-bottom: 1px solid #ccc">
                                    <asp:TextBox ID="txtContent" runat="server" TextMode="MultiLine" Rows="3" Width="95%" style="font-family: Arial, Helvetica, Sans-Serif; font-size: 10pt;" />
                                    <div><asp:Button ID="btSubmitShoutout" runat="server" Text="ShoutOut!" /></div>
                                </td>
                            </tr>
                        </table>
                    </telerik:RadPageView>
                </telerik:RadMultiPage>
                <asp:Repeater ID="rptShoutouts" runat="server">
                    <HeaderTemplate>
                        <table cellpadding="5" cellspacing="0" border="0" style="width: 100%" class="Shoutout">
                    </HeaderTemplate>
                    <ItemTemplate>
                        <tr style="vertical-align: top">
                            <td style="width: 75px; border-bottom: 1px dashed #ccc"><asp:Image ID="imgUserIcon" runat="server" ImageUrl='<%# GetUserIcon(Eval("icon_filename_txt").ToString()) %>' Width="75" /></td>
                            <td style="width: 100%; padding: 7px 0px; border-bottom: 1px dashed #ccc">
                                <asp:Label runat="server" CssClass="username" Text='<%# Eval("UserName") %>' Font-Bold="true" />
                                <asp:Label runat="server" CssClass="content" Text='<%# formatContent(Eval("content_txt").ToString()) %>' />
                                <div style="float: right"><asp:Label runat="server" Text='<%# formatDisplayPostingTime((DateTime)Eval("create_dttm")) %>' CssClass="date" ForeColor="#999999" /></div></td>
                        </tr>
                    </ItemTemplate>
                    <FooterTemplate>
                        </table>
                        <table cellpadding="0" cellspacing="0" border="0" style="width: 100%">
                            <tr>
                                <td style="padding: 7px 5px;">
                                    <asp:LinkButton runat="server" ID="btNewerPost" OnClick="btNewerPost_Click" OnPreRender="btNewerPost_PreRender" Font-Underline="false"><asp:Image ID="Image1" runat="server" ImageUrl="~/Images/btn-arrow-up.gif" ImageAlign="AbsMiddle" />&nbsp;<asp:Label runat="server" Text="Newer posts" Font-Underline="true" /></asp:LinkButton></td>
                                <td style="text-align: right; padding: 7px 5px;">
                                    <asp:LinkButton runat="server" ID="btOlderPost" OnClick="btOlderPost_Click" OnPreRender="btOlderPost_PreRender" Font-Underline="false"><asp:Image ID="Image2" runat="server" ImageUrl="~/Images/btn-arrow-down.gif" ImageAlign="AbsMiddle" />&nbsp;<asp:Label runat="server" Text="Older posts" Font-Underline="true" /></asp:LinkButton></td>
                            </tr>
                        </table>
                    </FooterTemplate>
                </asp:Repeater>
            </article>
        </div>
        <div style="clear: both;"></div>
    </div>
    <div style="clear: both;"></div>
</asp:Content>
